# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=py3-graphviz
pkgver=0.14.1
pkgrel=0
pkgdesc="Simple interface for Graphviz"
url="https://github.com/xflr6/graphviz"
arch="noarch"
license="MIT"
replaces="py-graphviz" # for backwards compatibility
provides="py-graphviz=$pkgver-r$pkgrel" # for backwards compatibility
depends="graphviz python3"
makedepends="py3-setuptools"
checkdepends="pytest py3-pytest-cov py3-pytest-mock"
source="https://github.com/xflr6/graphviz/archive/$pkgver/graphviz-$pkgver.tar.gz
	use-std-mock.patch
	"
builddir="$srcdir/graphviz-$pkgver"

build() {
	python3 setup.py --quiet build
}

check() {
	pytest
}

package() {
	python3 setup.py --quiet install --prefix=/usr --root="$pkgdir"
}

sha512sums="32c230c95c77255505d99e55c294d13074ac06333cf08b1d019c830334c98ce01bd4c01cd815a0692a70665715e0a195fdd60e4c95e05c8692499555ed0ed519  graphviz-0.14.1.tar.gz
d84171748e36cb48c6c6fa38e0596b42946cee3ad3a3a6b607da4828e138f34656a40ca4d91ddcebb89669edec29a7dd4c227d13d3900c51b14bfa971f874f4f  use-std-mock.patch"
